package com.yike.product.service;

import com.yike.product.entity.Category;
import com.yike.product.param.CategoryPageParam;
import com.yike.common.base.BaseService;
import com.yike.common.pagination.Paging;
import com.yike.product.param.CategoryParam;
import com.yike.product.vo.CategoryVo;

/**
 * 商品分类 服务类
 *
 * @author Sakura
 * @since 2024-09-02
 */
public interface CategoryService extends BaseService<Category> {

    /**
     * 保存
     *
     * @param categoryParam
     * @return
     * @throws Exception
     */
    boolean saveCategory(CategoryParam categoryParam) throws Exception;

    /**
     * 修改
     *
     * @param categoryParam
     * @return
     * @throws Exception
     */
    boolean updateCategory(CategoryParam categoryParam) throws Exception;

    /**
     * 删除
     *
     * @param id
     * @return
     * @throws Exception
     */
    boolean deleteCategory(Long id) throws Exception;


    /**
     * 获取分页对象
     *
     * @param categoryPageParam
     * @return
     * @throws Exception
     */
    Paging<CategoryVo> getCategoryPageList(CategoryPageParam categoryPageParam) throws Exception;

}
